package org.fuys.etp.core.model.vo;

import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.fuys.etp.core.reject.EtpRejectHandler;

/**
 * @projectName: fuys-etp
 * @package: org.fuys.etp.core.model.vo
 * @className: TpBaseConfigVO
 * @author: WangJing
 * @description: 线程池基础配置视图类
 * @date: 2025/2/6 15:40
 * @version: 1.0
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class TpBaseConfigVO {
    private Integer version;

    /**
     * 核心线程数
     */
    private Integer poolCoreSize;

    /**
     * 最大线程数
     */
    private Integer poolMaxSize;

    /**
     * 线程空闲时间
     */
    private Integer poolKeepAliveTime;

    /**
     * 线程空闲时间单位 默认为分钟
     */
    private Object poolAliveTimeUnit;

    /**
     * 队列大小
     */
    private Integer workQueueSize;

    /**
     * 负载检测间隔时间
     */
    private Integer selfCheckInterval;

    /**
     * 负载检测间隔时间单位 默认为分钟
     */
    private String selfCheckIntervalUnit;

    /**
     * 拒绝策略处理类的Bean名称
     */
    private String rejectHandleBean;

    private Integer rejectCheckThreshold;

    private Integer rejectAlertThreshold;

    private EtpRejectHandler rejectHandle;

    /**
     * cpu占用率限制
     */
    private Integer cpuPointLimit;

    /**
     * 内存占用率限制
     */
    private Integer memoryPointLimit;

    /**
     * 配置描述
     */
    private String description;

}
